import 'package:my_app_01/service/HttpUtils.dart';

class DashboardApi {
  /// 获取轮播图数据
  static Future<Map> getImageList() async {
    var response = await HttpUtils.post(
      "/admin-api/cms_layer_info/selectPageList",
      data: {"pageNo": 1, "pageSize": 999},
    );
    return response;
  }

  /// 获取通知数据
  static Future<Map> getNoticeList() async {
    var response = await HttpUtils.post(
      "/admin-api/mh_sys_notice_info/selectPageList",
      data: {"pageNo": 1, "pageSize": 999, "readStatus": "0"},
    );
    return response;
  }

  /// 获取资金收入数据
  static Future<Map> getIncomeInfo(data) async {
    var response = await HttpUtils.post(
      "/datacenter-api/mh_cs_dcenter_school_income/selectPageListSchoolIncomeCnt",
      data: data,
    );
    return response;
  }

  /// 获取资金支出数据
  static Future<Map> getCostInfo(data) async {
    var response = await HttpUtils.post(
      "/datacenter-api/mh_cs_dcenter_school_pay/selectPageListSchoolPayCnt",
      data: data,
    );
    return response;
  }

  /// 获取采购数据统计
  static Future<Map> getPurchaseData(data) async {
    var response = await HttpUtils.post(
      "/datacenter-api/mh_cs_dcenter_school_order/selectPageListSchoolOrderCnt",
      data: data,
    );
    return response;
  }

  /// 获取用餐数据统计
  static Future<Map> getMealsData(data) async {
    var response = await HttpUtils.post(
      "/datacenter-api/mh_cs_dcenter_school_meal/selectPageListSchoolMealCnt",
      data: data,
    );
    return response;
  }
}
